package com.bigflexlib.ds.op
{
	import com.bigflexlib.ds.container.IRContainer;
	import com.bigflexlib.ds.container.IWContainer;
	import com.bigflexlib.ds.container.bag.IWBag;

	public class ContainerMappingOp extends AbstractContainerMappingOp
	{
		

		private var oBag:IWBag;
		
		
		
		public function ContainerMappingOp(iContainer:IRContainer, oBag:IWBag, iMappingFunction:Function=null, iCacheMappingResults:Boolean=false)
		{
			
			this.oBag = oBag;
			
			super( iContainer, oBag, iMappingFunction, iCacheMappingResults );
		
		}
		
		
		


		override protected function m( e:*, m:int ):void
		{
		
			oBag.add( e , m );

		}


		override public function dispose():void
		{
			
			super.dispose();
			
			oBag = null;
			
		}		
		
		
		
	}
}